﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;
using IndoReputation.Commons;

namespace IndoReputation.Views.ViewModels
{
    public class RankTypeViewModel
    {
        [Required]
        public int ID
        {
            set;
            get;
        }

        [Required(ErrorMessage = "Please type the Name")]
        [StringLength(256, ErrorMessage = "String may not be longer than 256 characters")]
        [PlaceHolder("Enter name here")]
        public string Name
        {
            set;
            get;
        }

        [Required(ErrorMessage = "Please type the Value")]
        [Range(1, Int16.MaxValue, ErrorMessage = "Please type the Value of Rank")]
        public int RankValue
        {
            set;
            get;
        }

        [DataType(DataType.MultilineText)]
        [StringLength(512, ErrorMessage = "String may not be longer than 512 characters")]
        [PlaceHolder("Enter description here")]
        public string Description
        {
            set;
            get;
        }
        public DateTime? CreateAt
        {
            set;
            get;
        }
        public int? CreateBy
        {
            set;
            get;
        }
    }
}